Optimal. Leaf size=128 \[ \frac {b x \sqrt {c+d x^2}}{2 f}-\frac {(2 b d e-b c f-2 a d f) \tanh ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {c+d x^2}}\right )}{2 \sqrt {d} f^2}+\frac {(b e-a f) \sqrt {d e-c f} \tanh ^{-1}\left (\frac {\sqrt {d e-c f} x}{\sqrt {e} \sqrt {c+d x^2}}\right )}{\sqrt {e} f^2} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.10, antiderivative size = 128, normalized size of antiderivative = 1.00, number of steps
used = 6, number of rules used = 6, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.214, Rules used = {542, 537, 223,
212, 385, 214} \begin {gather*} -\frac {\tanh ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {c+d x^2}}\right ) (-2 a d f-b c f+2 b d e)}{2 \sqrt {d} f^2}+\frac {(b e-a f) \sqrt {d e-c f} \tanh ^{-1}\left (\frac {x \sqrt {d e-c f}}{\sqrt {e} \sqrt {c+d x^2}}\right )}{\sqrt {e} f^2}+\frac {b x \sqrt {c+d x^2}}{2 f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 214
Rule 223
Rule 385
Rule 537
Rule 542
Rubi steps
\begin {align*} \int \frac {\left (a+b x^2\right ) \sqrt {c+d x^2}}{e+f x^2} \, dx &=\frac {b x \sqrt {c+d x^2}}{2 f}+\frac {\int \frac {-c (b e-2 a f)+(-2 b d e+b c f+2 a d f) x^2}{\sqrt {c+d x^2} \left (e+f x^2\right )} \, dx}{2 f}\\ &=\frac {b x \sqrt {c+d x^2}}{2 f}+\frac {((b e-a f) (d e-c f)) \int \frac {1}{\sqrt {c+d x^2} \left (e+f x^2\right )} \, dx}{f^2}-\frac {(2 b d e-b c f-2 a d f) \int \frac {1}{\sqrt {c+d x^2}} \, dx}{2 f^2}\\ &=\frac {b x \sqrt {c+d x^2}}{2 f}+\frac {((b e-a f) (d e-c f)) \text {Subst}\left (\int \frac {1}{e-(d e-c f) x^2} \, dx,x,\frac {x}{\sqrt {c+d x^2}}\right )}{f^2}-\frac {(2 b d e-b c f-2 a d f) \text {Subst}\left (\int \frac {1}{1-d x^2} \, dx,x,\frac {x}{\sqrt {c+d x^2}}\right )}{2 f^2}\\ &=\frac {b x \sqrt {c+d x^2}}{2 f}-\frac {(2 b d e-b c f-2 a d f) \tanh ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {c+d x^2}}\right )}{2 \sqrt {d} f^2}+\frac {(b e-a f) \sqrt {d e-c f} \tanh ^{-1}\left (\frac {\sqrt {d e-c f} x}{\sqrt {e} \sqrt {c+d x^2}}\right )}{\sqrt {e} f^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.38, size = 141, normalized size = 1.10 \begin {gather*} \frac {b f x \sqrt {c+d x^2}+\frac {2 (b e-a f) \sqrt {-d e+c f} \tan ^{-1}\left (\frac {-f x \sqrt {c+d x^2}+\sqrt {d} \left (e+f x^2\right )}{\sqrt {e} \sqrt {-d e+c f}}\right )}{\sqrt {e}}+\frac {(2 b d e-b c f-2 a d f) \log \left (-\sqrt {d} x+\sqrt {c+d x^2}\right )}{\sqrt {d}}}{2 f^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(706\) vs.
\(2(106)=212\).
time = 0.18, size = 707, normalized size = 5.52 Too large to display
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.25, size = 786, normalized size = 6.14 \begin {gather*} \left [\frac {2 \, \sqrt {d x^{2} + c} b d f x + {\left (2 \, b d e - {\left (b c + 2 \, a d\right )} f\right )} \sqrt {d} \log \left (-2 \, d x^{2} + 2 \, \sqrt {d x^{2} + c} \sqrt {d} x - c\right ) - {\left (a d f - b d e\right )} \sqrt {-{\left (c f - d e\right )} e^{\left (-1\right )}} \log \left (\frac {c^{2} f^{2} x^{4} - 4 \, {\left (c f x^{3} e - {\left (2 \, d x^{3} + c x\right )} e^{2}\right )} \sqrt {d x^{2} + c} \sqrt {-{\left (c f - d e\right )} e^{\left (-1\right )}} + {\left (8 \, d^{2} x^{4} + 8 \, c d x^{2} + c^{2}\right )} e^{2} - 2 \, {\left (4 \, c d f x^{4} + 3 \, c^{2} f x^{2}\right )} e}{f^{2} x^{4} + 2 \, f x^{2} e + e^{2}}\right )}{4 \, d f^{2}}, \frac {2 \, \sqrt {d x^{2} + c} b d f x + 2 \, {\left (2 \, b d e - {\left (b c + 2 \, a d\right )} f\right )} \sqrt {-d} \arctan \left (\frac {\sqrt {-d} x}{\sqrt {d x^{2} + c}}\right ) - {\left (a d f - b d e\right )} \sqrt {-{\left (c f - d e\right )} e^{\left (-1\right )}} \log \left (\frac {c^{2} f^{2} x^{4} - 4 \, {\left (c f x^{3} e - {\left (2 \, d x^{3} + c x\right )} e^{2}\right )} \sqrt {d x^{2} + c} \sqrt {-{\left (c f - d e\right )} e^{\left (-1\right )}} + {\left (8 \, d^{2} x^{4} + 8 \, c d x^{2} + c^{2}\right )} e^{2} - 2 \, {\left (4 \, c d f x^{4} + 3 \, c^{2} f x^{2}\right )} e}{f^{2} x^{4} + 2 \, f x^{2} e + e^{2}}\right )}{4 \, d f^{2}}, \frac {2 \, \sqrt {d x^{2} + c} b d f x + 2 \, {\left (a d f - b d e\right )} \sqrt {c f - d e} \arctan \left (\frac {{\left (c f x^{2} - {\left (2 \, d x^{2} + c\right )} e\right )} \sqrt {d x^{2} + c} \sqrt {c f - d e} e^{\left (-\frac {1}{2}\right )}}{2 \, {\left (c d f x^{3} + c^{2} f x - {\left (d^{2} x^{3} + c d x\right )} e\right )}}\right ) e^{\left (-\frac {1}{2}\right )} + {\left (2 \, b d e - {\left (b c + 2 \, a d\right )} f\right )} \sqrt {d} \log \left (-2 \, d x^{2} + 2 \, \sqrt {d x^{2} + c} \sqrt {d} x - c\right )}{4 \, d f^{2}}, \frac {\sqrt {d x^{2} + c} b d f x + {\left (a d f - b d e\right )} \sqrt {c f - d e} \arctan \left (\frac {{\left (c f x^{2} - {\left (2 \, d x^{2} + c\right )} e\right )} \sqrt {d x^{2} + c} \sqrt {c f - d e} e^{\left (-\frac {1}{2}\right )}}{2 \, {\left (c d f x^{3} + c^{2} f x - {\left (d^{2} x^{3} + c d x\right )} e\right )}}\right ) e^{\left (-\frac {1}{2}\right )} + {\left (2 \, b d e - {\left (b c + 2 \, a d\right )} f\right )} \sqrt {-d} \arctan \left (\frac {\sqrt {-d} x}{\sqrt {d x^{2} + c}}\right )}{2 \, d f^{2}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\left (a + b x^{2}\right ) \sqrt {c + d x^{2}}}{e + f x^{2}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {\left (b\,x^2+a\right )\,\sqrt {d\,x^2+c}}{f\,x^2+e} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________